package com.sell.enums;

import lombok.Getter;

/**
 * @author: lichujun
 * @date: 2018-08-15
 */
@Getter
public enum SellExceptionEnum {

    PARAM_ERROR(1, "参数不正确"),

    PRODUCT_NOT_EXIST(10, "商品不存在"),

    PRODUCT_STOCK_ERROR(11, "商品库存不正确"),

    ORDER_NOT_EXIST(12, "订单不存在"),

    DETAIL_NOT_EXIST(13, "订单详情不存在"),

    ORDER_STATUS_ERROR(14, "订单状态不正确"),

    ORDER_UPDATE_FAIL(15, "更新库存失败"),

    ORDER_DETAIL_EMPTY(16, "订单中无订单详情"),

    ORDER_PAY_STATUS_ERROR(17, "修改订单支付状态失败"),

    CART_EMPTY(18, "购物车为空"),

    ORDER_OWNER_ERROR(19, "本人没有这个订单"),

    WECHAT_MP_ERROR(20, "微信公众号账号方面错误"),

    WXPAY_MONEY_VERITY_ERROR(21, "微信金额校验出错"),

    ORDER_CANCEL_SUCCESS(22, "订单取消成功"),

    ORDER_FINISH_SUCCESS(23, "订单取消成功"),

    PRODUCT_STATUS_ERROR(24, "商品状态错误"),

    ON_SALE_SUCCESS(25, "上架商品成功"),

    OFF_SALE_SUCCESS(25, "下架商品成功"),

    ;

    private Integer code;

    private String msg;

    SellExceptionEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
